<?php

class csNavbar {
    public $element_tbl;
    public $delimiter = '>>';

    public function __construct($params = null) {
        $this -> element_tbl = array();
        if (isset($params['delimiter'])) $this -> delimiter = $params['delimiter'];
    }
    
    public function add($name, $url = null) {
    	foreach ($this -> element_tbl as $eid => $element) {
    		$this -> element_tbl[$eid]['active'] = false;
			$this -> element_tbl[$eid]['last'] = false;
    	}
    	
    	$this -> element_tbl[] = array(
    		'name' => $name,
    		'url' => $url,
    		'active' => true,
    		'last' => true
    	);
    }
}

?>
